/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.test2.entity;

import org.hibernate.validator.constraints.Length;
import javax.validation.constraints.NotNull;

import com.thinkgem.jeesite.common.persistence.DataEntity;

import java.util.List;

/**
 * 养殖场管理Entity
 * @author dby
 * @version 2020-09-15
 */
public class Farm extends DataEntity<Farm> {
	
	private static final long serialVersionUID = 1L;
	private String name;		// 负责人姓名
	private String farmType;		// 养殖类型
	private String farmName;		// 养殖场名称
	private String idcard;		// 负责人身份证号
	private String phone;		// 负责人手机号
	private String address;		// 详细地址
	private String creditCode;		// 统一社会信用代码
	private String breedCode;		// 畜禽养殖代码
	private String animalCertificate;		// 动物防疫条件许可证号
	private String businessCertificate;		// 种蓄经营许可证号
	private String pollutantDischargingLicense;		// 排污许可证号
	private String environmentalFlag;		// 是否环评
	private String violateFlag;		// 是否存在违建用房
	private String handleFacilities;		// 粪污处理设施
	private Integer status;		// 启用状态 0=不可用 1=可用
	private String sort;		// 排序
	private List<FarmClass> list;
	public Farm() {
		super();
	}

	public Farm(String id){
		super(id);
	}

	@Length(min=0, max=80, message="负责人姓名长度必须介于 0 和 80 之间")
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	@Length(min=0, max=10, message="养殖类型长度必须介于 0 和 10 之间")
	public String getFarmType() {
		return farmType;
	}

	public void setFarmType(String farmType) {
		this.farmType = farmType;
	}
	
	@Length(min=0, max=30, message="养殖场名称长度必须介于 0 和 30 之间")
	public String getFarmName() {
		return farmName;
	}

	public void setFarmName(String farmName) {
		this.farmName = farmName;
	}
	
	@NotNull(message="负责人身份证号不能为空")
	public String getIdcard() {
		return idcard;
	}

	public void setIdcard(String idcard) {
		this.idcard = idcard;
	}
	
	@NotNull(message="负责人手机号不能为空")
	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}
	
	@Length(min=1, max=30, message="详细地址长度必须介于 1 和 30 之间")
	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}
	
	@Length(min=0, max=50, message="统一社会信用代码长度必须介于 0 和 50 之间")
	public String getCreditCode() {
		return creditCode;
	}

	public void setCreditCode(String creditCode) {
		this.creditCode = creditCode;
	}
	
	@Length(min=0, max=50, message="畜禽养殖代码长度必须介于 0 和 50 之间")
	public String getBreedCode() {
		return breedCode;
	}

	public void setBreedCode(String breedCode) {
		this.breedCode = breedCode;
	}
	
	@Length(min=0, max=50, message="动物防疫条件许可证号长度必须介于 0 和 50 之间")
	public String getAnimalCertificate() {
		return animalCertificate;
	}

	public void setAnimalCertificate(String animalCertificate) {
		this.animalCertificate = animalCertificate;
	}
	
	@Length(min=0, max=50, message="种蓄经营许可证号长度必须介于 0 和 50 之间")
	public String getBusinessCertificate() {
		return businessCertificate;
	}

	public void setBusinessCertificate(String businessCertificate) {
		this.businessCertificate = businessCertificate;
	}
	
	@Length(min=0, max=50, message="排污许可证号长度必须介于 0 和 50 之间")
	public String getPollutantDischargingLicense() {
		return pollutantDischargingLicense;
	}

	public void setPollutantDischargingLicense(String pollutantDischargingLicense) {
		this.pollutantDischargingLicense = pollutantDischargingLicense;
	}
	
	@Length(min=0, max=1, message="是否环评长度必须介于 0 和 1 之间")
	public String getEnvironmentalFlag() {
		return environmentalFlag;
	}

	public void setEnvironmentalFlag(String environmentalFlag) {
		this.environmentalFlag = environmentalFlag;
	}
	
	@Length(min=0, max=1, message="是否存在违建用房长度必须介于 0 和 1 之间")
	public String getViolateFlag() {
		return violateFlag;
	}

	public void setViolateFlag(String violateFlag) {
		this.violateFlag = violateFlag;
	}
	
	@Length(min=0, max=50, message="粪污处理设施长度必须介于 0 和 50 之间")
	public String getHandleFacilities() {
		return handleFacilities;
	}

	public void setHandleFacilities(String handleFacilities) {
		this.handleFacilities = handleFacilities;
	}
	
	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}
	
	@Length(min=0, max=4, message="排序长度必须介于 0 和 4 之间")
	public String getSort() {
		return sort;
	}

	public void setSort(String sort) {
		this.sort = sort;
	}

	public List<FarmClass> getList() {
		return list;
	}

	public void setList(List<FarmClass> list) {
		this.list = list;
	}
}